import 'package:flutter/material.dart';
import 'package:get/get_state_manager/get_state_manager.dart';
import 'package:industry_net/base/common/util.dart';
import 'package:industry_net/base/component/component.dart';
import 'package:industry_net/pages/me/setup/login_pwd/controller.dart';

class LoginPwdPage extends GetView<LoginPwdController> {
  const LoginPwdPage({Key? key}) : super(key: key);

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: detailAppBar(context, title: '设置密码'),
      backgroundColor: ColorsUtil.white,
      body: Padding(
        padding: EdgeInsets.symmetric(horizontal: gap12),
        child: Column(
          children: [
            SizedBox(
              height: 32.w,
            ),
            Text(
              '当前手机号' + controller.state.phone.phone,
              style: pfSCStyle(color: ColorsUtil.title, fontSize: font17),
            ),
            SizedBox(
              height: 10.w,
            ),
            UITextField(
              hintText: '填写原密码',
              controller: controller.state.oldEditCtrl,
            ),
            UITextField(
              hintText: '填写新密码',
              controller: controller.state.newEditCtrl,
            ),
            UITextField(
              hintText: '再次填写确认',
              controller: controller.state.new1EditCtrl,
            ),
            Container(
              alignment: Alignment.centerLeft,
              child: TextButton(
                onPressed: controller.actionForgot,
                child: Text(
                  '忘记原密码？',
                  style:
                      pfMediumStyle(color: ColorsUtil.blue, fontSize: font13),
                ),
              ),
            ),
            SizedBox(
              height: 30.w,
            ),
            ExpandedButton(
              text: '确认',
              onPressed: controller.sure,
            )
          ],
        ),
      ),
    );
  }
}
